package magicboard.classifier.patterndb
{

	public class PatternDB
	{
		// --------------------------------------------------------------------------------------------
		/** Return */
		public static function get classes():Object{
			return _classes;
		}
		
		// --------------------------------------------------------------------------------------------
		/** Return */
		public static function get references():Object{
			return _references;
		}
		
		// --------------------------------------------------------------------------------------------
		// Patterns data
		/** Pattern classes and features */
		private static var _classes:Object = {
			0:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			1:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			2:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			3:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			4:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			5:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			6:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			7:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			8:["segmentcount", "startsin", "startcos", "endsin", "endcos"],
			9:["segmentcount", "startsin", "startcos", "endsin", "endcos"]
		};
		/** Reference patterns for 1 digit */
		private static var _references:Object = {
			0:[
				"(206,195), (206,194), (207,194), (207,193), (206,193), (205,193), (205,194), (204,194), (203,195), (202,196), (201,197), (199,198), (198,200), (197,201), (192,208), (191,210), (190,212), (189,214), (188,217), (187,219), (186,222), (186,225), (185,229), (184,232), (183,236), (182,239), (181,243), (181,247), (180,250), (180,254), (179,258), (179,262), (178,267), (178,271), (179,275), (179,278), (180,282), (181,285), (182,289), (183,293), (184,296), (186,300), (187,303), (189,307), (191,309), (193,312), (196,315), (199,317), (201,319), (204,321), (207,322), (211,323), (214,324), (217,324), (220,324), (223,323), (225,322), (228,321), (231,320), (233,318), (236,316), (239,313), (241,311), (244,308), (246,306), (248,303), (250,300), (252,297), (254,294), (256,291), (258,287), (259,283), (261,279), (263,276), (264,272), (265,268), (266,264), (267,260), (267,257), (268,253), (268,249), (269,246), (269,243), (269,240), (268,236), (268,233), (268,229), (267,226), (267,223), (266,220), (265,217), (264,214), (263,212), (262,209), (260,207), (258,205), (257,203), (255,202), (253,200), (251,199), (249,197), (247,196), (245,195), (243,193), (241,192), (239,192), (237,191), (234,191), (232,190), (229,190), (227,190), (224,190), (221,190), (210,194), (210,194)"
			],
			1:[
				"(666,181), (667,181), (668,179), (669,177), (671,171), (673,165), (674,163), (676,157), (677,155), (678,153), (682,149), (683,147), (687,141), (688,139), (692,133), (693,131), (697,125), (698,124), (702,120), (702,119), (706,115), (707,113), (708,111), (709,109), (710,107), (710,105), (711,103), (712,101), (712,99), (713,98), (713,97), (714,97), (714,96), (714,98), (714,106), (714,109), (712,117), (712,125), (710,135), (710,138), (710,146), (710,149), (710,152), (710,160), (710,162), (710,170), (710,172), (710,175), (710,177), (710,179), (710,181), (710,184), (710,186), (710,188), (710,190), (710,192), (710,194), (710,197), (710,199), (710,201), (710,204), (710,206), (710,209), (710,211), (710,214), (710,216), (710,219), (710,221), (710,224), (710,226), (710,228), (709,230), (709,232), (709,233), (709,235), (709,237), (709,239), (709,241), (709,242), (709,244), (709,245), (709,246), (709,247), (709,248), (709,249), (709,250), (709,251), (709,252), (709,252)",
				"(557,177), (558,177), (559,176), (560,175), (561,174), (562,173), (564,172), (566,170), (568,168), (570,166), (572,165), (574,163), (575,162), (577,160), (579,158), (581,156), (583,154), (585,152), (586,150), (588,148), (589,147), (590,146), (591,145), (592,144), (593,144), (593,143), (593,144), (594,145), (594,147), (594,149), (594,152), (594,155), (594,159), (594,163), (594,167), (594,171), (594,175), (594,180), (594,184), (594,188), (594,191), (594,194), (594,197), (594,203), (595,206), (595,208), (595,210), (595,212), (595,213), (595,214), (595,214)"
			],
			2:[
				"(166,175), (165,175), (164,175), (164,174), (164,173), (165,172), (165,171), (167,169), (169,167), (171,165), (173,163), (175,161), (178,159), (180,158), (182,157), (184,157), (187,156), (189,156), (192,156), (195,157), (198,157), (200,158), (203,159), (205,160), (207,161), (209,162), (210,164), (212,166), (213,167), (213,169), (211,181), (210,183), (208,186), (207,188), (205,191), (203,194), (202,198), (200,201), (198,204), (196,207), (194,209), (193,212), (191,215), (189,218), (188,221), (186,223), (184,226), (183,229), (181,231), (179,234), (178,236), (176,239), (175,241), (173,243), (172,245), (170,247), (169,249), (168,250), (168,251), (167,252), (167,253), (166,253), (166,254), (167,254), (168,254), (169,254), (171,254), (173,253), (175,253), (177,252), (180,252), (182,252), (184,252), (187,252), (189,252), (192,252), (195,252), (199,252), (202,252), (204,251), (207,251), (209,251), (211,251), (213,251), (214,251), (215,252), (216,252), (217,252), (218,252), (219,252), (219,252)"
			],
			3:[
				"(161,204), (160,204), (159,204), (160,203), (161,202), (163,200), (165,198), (168,196), (171,194), (175,192), (178,190), (182,189), (185,188), (188,188), (191,189), (193,190), (195,192), (196,194), (197,197), (198,200), (198,202), (198,205), (198,207), (197,210), (196,213), (194,216), (192,219), (190,222), (187,225), (184,228), (181,230), (178,233), (176,234), (175,235), (174,235), (175,234), (188,228), (191,227), (194,228), (196,229), (199,230), (201,233), (202,235), (204,239), (205,242), (207,245), (208,249), (208,252), (209,255), (210,259), (210,263), (210,267), (209,271), (209,275), (208,278), (206,282), (205,285), (203,288), (201,290), (198,292), (195,294), (191,295), (186,296), (182,297), (177,297), (173,297), (169,297), (165,297), (162,297), (159,296), (159,296)"
			],
			4:[
				"(398,283), (399,282), (399,281), (400,280), (399,279), (400,279), (400,280), (400,281), (400,282), (400,284), (399,286), (399,289), (398,293), (397,296), (396,300), (394,304), (393,309), (391,314), (389,319), (387,324), (386,329), (385,333), (386,346), (387,347), (388,347), (388,348), (388,349), (389,350), (390,350), (392,351), (394,351), (397,351), (401,351), (405,350), (410,350), (414,350), (418,350), (421,350), (424,350), (425,350), (427,350), (428,350), (428,351), (429,351), (429,350), (430,348), (430,346), (431,344), (432,340), (433,337), (433,332), (434,328), (435,323), (436,318), (436,314), (436,310), (437,307), (437,305), (437,303), (437,302), (437,301), (437,302), (437,304), (436,307), (436,311), (435,317), (434,325), (433,333), (432,341), (431,349), (430,357), (429,363), (428,369), (428,373), (427,377), (427,380), (427,381), (427,382), (426,382), (426,382)"
			],
			5:[
				"(310,265), (311,265), (310,265), (309,265), (308,265), (306,265), (303,265), (301,265), (298,265), (295,265), (292,265), (290,265), (287,265), (285,265), (283,265), (282,265), (281,265), (280,265), (279,265), (278,265), (278,271), (278,274), (277,278), (277,283), (276,287), (276,292), (275,296), (274,299), (273,302), (273,305), (272,307), (272,309), (271,311), (271,313), (270,315), (270,316), (269,317), (269,318), (270,317), (271,316), (272,315), (274,313), (275,312), (277,311), (279,309), (282,308), (284,307), (286,307), (289,307), (291,307), (294,308), (297,308), (299,310), (302,311), (304,313), (305,315), (307,317), (307,319), (308,322), (308,324), (308,327), (308,329), (308,332), (308,334), (307,336), (306,339), (305,341), (304,343), (302,345), (301,347), (300,348), (298,350), (297,351), (295,352), (292,352), (290,353), (287,353), (284,353), (281,352), (278,352), (274,351), (271,349), (271,349)"
			],
			6:[
				"(222,301), (223,301), (223,300), (223,299), (222,299), (221,299), (220,299), (218,300), (216,300), (214,301), (213,302), (210,304), (208,305), (206,307), (203,310), (201,312), (199,315), (196,317), (194,320), (191,324), (189,327), (187,331), (185,334), (183,338), (182,342), (180,346), (179,350), (178,355), (178,359), (177,363), (177,367), (177,372), (178,377), (179,382), (180,387), (181,391), (183,396), (185,400), (187,403), (189,406), (192,408), (194,410), (197,412), (201,413), (204,414), (207,414), (211,414), (214,413), (218,413), (220,411), (223,410), (226,408), (228,406), (230,404), (233,401), (234,399), (236,396), (237,394), (238,391), (239,388), (239,385), (239,383), (239,380), (238,378), (238,375), (236,373), (235,372), (234,370), (232,368), (231,367), (229,366), (228,364), (226,363), (224,362), (222,361), (220,361), (218,360), (208,360), (206,361), (203,362), (201,363), (199,364), (197,366), (195,368), (193,370), (191,372), (187,377), (186,379), (186,379)"
			],
			7:[
				"(497,138), (499,138), (502,138), (504,138), (510,136), (512,136), (518,134), (521,134), (523,134), (525,134), (527,134), (529,134), (531,134), (533,134), (535,134), (538,134), (539,134), (542,134), (544,134), (546,134), (548,134), (549,134), (550,134), (551,134), (552,134), (553,134), (554,133), (555,133), (556,133), (557,133), (556,133), (555,135), (554,136), (554,139), (553,140), (553,143), (552,145), (550,151), (550,152), (550,154), (549,155), (549,156), (549,157), (549,158), (549,160), (547,166), (545,173), (544,175), (544,176), (542,182), (541,183), (540,185), (539,187), (538,188), (538,190), (538,192), (537,194), (536,195), (535,197), (535,199), (534,200), (534,202), (533,205), (533,207), (533,209), (532,211), (532,212), (528,216), (528,217), (528,219), (527,221), (527,222), (526,224), (526,226), (526,228), (525,230), (525,232), (525,233), (524,235), (524,236), (524,238), (524,239), (523,240), (523,241), (522,242), (522,243), (521,243), (521,244), (521,245), (521,245)",
				"(285,422), (286,422), (287,422), (289,422), (297,422), (299,422), (301,422), (304,422), (307,422), (310,422), (318,422), (326,422), (334,422), (336,421), (342,419), (345,419), (353,417), (356,417), (364,417), (367,417), (370,417), (372,417), (373,417), (375,417), (376,417), (377,417), (378,417), (378,418), (374,426), (370,432), (366,438), (362,442), (356,448), (354,454), (350,458), (349,459), (348,461), (347,463), (346,465), (345,467), (341,471), (340,472), (338,478), (338,479), (337,481), (337,483), (336,484), (336,486), (335,487), (334,489), (334,491), (333,493), (332,495), (330,501), (329,503), (329,505), (329,506), (328,508), (328,509), (328,510), (328,511), (328,513), (328,514), (328,515), (328,516), (327,516), (327,516)"
			],
			8:[
				"(473,349), (473,348), (472,347), (471,347), (469,347), (468,348), (466,349), (463,350), (460,352), (457,354), (454,357), (451,361), (449,365), (447,369), (446,372), (446,376), (447,379), (449,382), (452,385), (456,387), (461,390), (466,392), (471,395), (476,398), (480,402), (483,406), (486,411), (487,416), (488,421), (488,425), (486,430), (485,434), (483,437), (480,440), (477,442), (474,443), (470,444), (466,444), (462,443), (458,442), (454,440), (451,437), (449,434), (447,430), (446,427), (445,423), (446,420), (447,416), (449,412), (451,408), (455,404), (458,400), (462,396), (466,393), (470,389), (474,386), (477,382), (480,379), (483,375), (486,371), (488,367), (489,363), (489,360), (489,357), (489,354), (488,352), (487,349), (486,347), (484,345), (481,344), (479,342), (476,342), (472,342), (469,342)"
			],
			9:[
				"(249,352), (250,351), (250,350), (251,349), (250,348), (249,348), (247,348), (245,349), (242,350), (239,352), (235,354), (231,357), (228,360), (224,364), (221,368), (218,372), (216,376), (214,381), (213,386), (213,391), (214,395), (215,400), (217,404), (219,407), (222,409), (225,410), (228,410), (232,409), (236,406), (240,403), (244,400), (248,396), (251,392), (254,389), (260,374), (261,370), (260,366), (260,363), (259,360), (258,358), (257,357), (256,356), (255,356), (254,357), (253,358), (253,359), (253,362), (253,364), (253,367), (254,370), (254,374), (255,378), (256,382), (256,387), (257,392), (257,398), (258,404), (258,410), (259,416), (259,422), (260,427), (260,431), (261,435), (261,439), (261,443), (261,447), (261,451), (261,454), (260,457), (260,460), (259,463), (259,465), (258,466), (257,468), (256,469), (255,470), (254,470), (253,471), (251,471), (249,472), (247,472), (245,472), (243,472), (241,472), (239,471), (239,471)"
			]
		};		
	}
}
